import {Redirect, Route, Switch} from "react-router-dom";
import Page from "../views/Page";
import Me from "../views/Me";
// import Other from "../views/Other";
import Page404 from "../views/Page404";
import Home from "../views/Home";
import React from "react";
import YouJi from "../views/YouJi";
import GongLue from "../views/GongLue";

function RouterView() {
  return (
    <Switch>
      <Route path='/page' component={Page}>
      </Route>
      <Route path='/me' component={Me}>
      </Route>
      <Route path='/404' component={Page404}>
      </Route>
      <Route path='/home' component={Home}>
      </Route>
      <Route path='/youji' component={YouJi}>
      </Route>
      <Route path='/gonglue' component={GongLue}>
      </Route>
      {/*<Redirect from='/' to='/404'/>*/}
      <Redirect from='/' to='/youji'/>
      {/*<Redirect from='*' to='/404'/>*/}
    </Switch>
  )
}

export default RouterView;
